<template>
    <div>
        <h1>{{ message }}</h1>
        <button @click="greet">greet</button>
    </div>
</template>

<script>
    export default{
        data(){
            return{
                message:'Hello,Vue 3!'
            }
        },
        methods:{
            greet(){
                this.message = 'Hello,' + this.$attrs.name + '!'
            }
        }
    }
</script>

<style scoped>
    .example{
        color: red;
    }
</style>